namespace OptionParser
{
    using System;
    using System.Reflection;
    using System.Collections;
    
    public class InputGetOptions : GetOptions
    {
        [Option ("-i", "Get data from file.")]
        public string InFile;
        
        public InputGetOptions()
        {
            InFile = "";
        }
        
        public override void ProcessArgs(string[] args)
        {
            base.ProcessArgs(args);
            
            // make sure we have at least an infile
            if (InFile == "" && RemainingArgs.Length < 1)
            {
                Console.Error.WriteLine("Please specify a file");
                Environment.Exit(1);
            }
            else if (InFile == "")
                InFile = RemainingArgs[0];
        }
    }
}
